/*
 * 作者:熊猫
 * 日期:2017 - 3 - 15 10 - 37 - 37
 *
 */

package net.lainiao.morethread.Chapter7.demo1;

import net.lainiao.morethread.MyDateUtils;

import java.util.Date;
import java.util.concurrent.Callable;
import java.util.concurrent.TimeUnit;

/**
 * Created by Administrator on 2017/3/15.
 */
public class SleepTwoSecondTask implements Callable<String> {
    @Override
    public String call() throws Exception {
        TimeUnit.SECONDS.sleep(2);
        return MyDateUtils.getFormatString(new Date());
    }
}
